package com.sxt.controller;

import javax.servlet.http.HttpSession;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
@RequestMapping("index")
public class IndexController {

	@RequestMapping("hello")
	public String hello(Model model,HttpSession httpSession) {
		model.addAttribute("myuser", "张三");
		httpSession.setAttribute("userName", "习大大");
		return "hello";
	}
}
